/**
 * http://usejsdoc.org/
 */
var req,res,
	fs = require('fs'),
	url = require('url');

/**创建初始变量函数*/
exports.init = function(response,request){
	res = response;
	req = request;
};

/**创建image函数*/
exports.image = function(){
	/**获取当前image的路径*/
	var realPath = __dirname + '/'+ url.parse('logo.jpg').pathname;
	/**应用fs中readFileSync同步API获取文件数据*/
	var indexPage = fs.readFileSync(realPath);
	res.writeHead( 200 , {"Content-Type":"image/jpg"});
	res.end(indexPage);
};